<style type="text/css">
.layui-form-item .layui-form-label{width:150px;}
.layui-form-item .layui-input-inline{max-width:80%;width:80%;}
.layui-form-mid{padding:0!important;}
.layui-form-mid code{color:#5FB878;}
textarea{height:80px!important;}
</style>
<form class="layui-form layui-form-pane" action="{:url()}" method="post" id="editForm">
    
	<div class="layui-form-item">
        <label class="layui-form-label">标识</label>
        <div class="layui-input-inline">
            <input type="text" class="layui-input field-type " name="type"  autocomplete="off" placeholder="请输入文字">
        </div>
    </div>
	
	<div class="layui-form-item">
        <label class="layui-form-label">描述</label>
        <div class="layui-input-inline">
            <input type="text" class="layui-input field-name " name="name"  autocomplete="off" placeholder="请输入文字">
        </div>
    </div>
	
    <div class="layui-form-item">
        <label class="layui-form-label">文字1</label>
        <div class="layui-input-inline">
			
			<textarea name="txt1" id="txt1">
				<?php echo isset($data_info['txt1']) ? $data_info['txt1'] : ''; ?>
			</textarea>
        </div>
    </div>
	
	
	
	  
	 
	<div class="layui-form-item">
        <div class="layui-input-block">
            <input type="hidden" class="field-id" name="id">
            <button type="submit" class="layui-btn" lay-submit="" lay-filter="formSubmit">提交</button>
            <a href="{:url('index')}" class="layui-btn layui-btn-primary ml10"><i class="aicon ai-fanhui"></i>返回</a>
        </div>
    </div>
	 
	 
</form>
<script>
var formData = {:json_encode($data_info)};
var $;
layui.use(['jquery', 'laydate', 'upload'], function() {
	$ = layui.jquery;
    var laydate = layui.laydate, layer = layui.layer, upload = layui.upload;
    upload.render({
        elem: '.layui-upload',
        url: '{:url("admin/annex/upload?thumb=no&water=no")}'
        ,method: 'post'
        ,before: function(input) {
            layer.msg('文件上传中...', {time:3000000});
        },done: function(res, index, upload) {
            var obj = this.item;
            if (res.code == 0) {
                layer.msg(res.msg);
                return false;
            }
            layer.closeAll();
            var input = $(obj).parents('.upload').find('.upload-input');
            if ($(obj).attr('lay-type') == 'image') {
                input.siblings('img').attr('src', res.data.file).show();
            }
            input.val(res.data.file);
        }
    });
    // 日期渲染
    laydate.render({elem: '.layui-date'});
	
	$("#clear_url").click(function(){
		$("input[name='url']").val("");
		$("#img_url").attr("src","").hide();
	});
	
	
});

</script>
{:editor(['txt1'], 'kindeditor')}
<script src="__ADMIN_JS__/footer.js"></script>